namespace C4F.DevKit.Bluetooth.ObjectExchange
{
    /// <summary>
    /// Interface representing the data that will be required to create
    /// an Authenticate Response header. This class should be inherited and
    /// implementation should be provided for GenerateRequestDigest().
    /// </summary>
    public interface IAuthenticateResponse
    {
        #region Properties

        /// <summary>
        /// Sets the private key used by the security model.
        /// </summary>
        byte[] PrivateKey
        {
            get;
            set;
        }

        /// <summary>
        /// Gets or sets the userId value to be sent in an Authenticate 
        /// Response header. This value should be set if the remote device
        /// requested for it. 
        /// </summary>
        string UserId
        {
            get;
            set;
        }

        /// <summary>
        /// Gets or sets the Nonce value used in the security model.
        /// Setting of this property is optional. If set, value should be the one sent by the
        /// remote device. 
        /// </summary>
        byte[] Nonce
        {
            get;
            set;
        }

        #endregion

        #region Public Functions/Methods

        /// <summary>
        /// Method for generating request digest. Assumes that the nonce value
        /// has been set. Note that the Reqest Digest value should be a byte 
        /// array of length 16.
        /// </summary>
        /// <returns>16 byte Request Digest.</returns>
        byte[] GenerateRequestDigest();

        #endregion
    }
}